Russian Math Olympiad Question.